<%-- 
    Document   : boxKhachHang
    Created on : 28-10-2011, 22:00:21
    Author     : VuTienIT
--%>

<%@page import="java.util.ArrayList" %>
<%@page import="model.pojo.*" %>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%
KhachHangPOJO ssDangNhap = null;
if(session.getAttribute("KhachHang")==null)
{
    ssDangNhap = new KhachHangPOJO();
    session.setAttribute("KhachHang", ssDangNhap);
}
else
{
    ssDangNhap = (KhachHangPOJO)session.getAttribute("KhachHang");
}
%>
<!DOCTYPE html>
<h2>Khách hàng</h2>
                    
<div class="sidebar_box_content">

        <div class="news_box">
        <div id="login_box">
            <%
            if(ssDangNhap.getTenTruyCap()==null){
            %>
              <table width="100%" border="0">
                <tr>
                    <td align="center">
                        <label>
                        <a href="DangNhap" >Đăng nhập</a>
                        </label>
                    </td>
                </tr>
                <tr>
                    <td align="center">
                        <label>
                        <a href="DangKy" >Đăng ký</a>
                        </label>
                    </td>
                </tr>
                
              </table>
            <%
           } else {
            %>
            <h4>Xin chào <a href="ThongTinKH?Page=info" /><b><%=ssDangNhap.getTenTruyCap()%></b></a></h4>
            <h4><a href="DangNhap?Action=Logout"/>Đăng xuất</a></h4>
            <%
           }
            %>
        </div>        
    </div>

</div> <!-- end of sidebar_box_content -->
